/******************************************************************************
//             INTEL CORPORATION PROPRIETARY INFORMATION
//  This software is supplied under the terms of a license agreement or
//  nondisclosure agreement with Intel Corporation and may not be copied
//  or disclosed except in accordance with the terms of that agreement.
//        Copyright (c) 2000-2001 Intel Corporation. All Rights Reserved.
//
//  Description:
//      Intel(R) JPEG library for X platform 
//
********************************************************************************/
#ifndef _IJXDEFS_H
#define _IJXDEFS_H

typedef int BOOL;
#ifndef FASLE
#define FALSE 0
#endif

#ifndef TRUE
#define TRUE  1
#endif

#ifndef NULL
#define NULL  0
#endif

#define  IJX_MARKER_NONE    0x0 
#define  IJX_MARKER_EOF     0x100
 
#define  IJX_MARKER_SOFS    0xA0 
#define  IJX_MARKER_SOFV    0xA1 
#define  IJX_MARKER_SOFW    0xA2 
#define  IJX_MARKER_SOFT    0xA3 

#define  IJX_MARKER_SOF     0xb0 
#define  IJX_MARKER_SOF0    0xc0 
#define  IJX_MARKER_SOF1    0xc1 
#define  IJX_MARKER_SOF2    0xc2 
#define  IJX_MARKER_SOF3    0xc3 
#define  IJX_MARKER_SOF5    0xc5 
#define  IJX_MARKER_SOF6    0xc6 
#define  IJX_MARKER_SOF7    0xc7 
#define  IJX_MARKER_SOF8    0xc8 
#define  IJX_MARKER_SOF9    0xc9 
#define  IJX_MARKER_SOFA    0xca 
#define  IJX_MARKER_SOFB    0xcb 
#define  IJX_MARKER_SOFD    0xcd 
#define  IJX_MARKER_SOFE    0xce 
#define  IJX_MARKER_SOFF    0xcf 

#define  IJX_MARKER_DHT     0xc4 
#define  IJX_MARKER_DAC     0xcc 

#define  IJX_MARKER_RST0    0xd0 
#define  IJX_MARKER_RST1    0xd1 
#define  IJX_MARKER_RST2    0xd2 
#define  IJX_MARKER_RST3    0xd3 
#define  IJX_MARKER_RST4    0xd4 
#define  IJX_MARKER_RST5    0xd5 
#define  IJX_MARKER_RST6    0xd6 
#define  IJX_MARKER_RST7    0xd7 

#define  IJX_MARKER_SOI     0xd8 
#define  IJX_MARKER_EOI     0xd9 
#define  IJX_MARKER_SOS     0xda 
#define  IJX_MARKER_DQT     0xdb 
#define  IJX_MARKER_DNL     0xdc 
#define  IJX_MARKER_DRI     0xdd 
#define  IJX_MARKER_DHP     0xde 
#define  IJX_MARKER_EXP     0xdf 

#define  IJX_MARKER_APP0    0xe0   // JFIF (hopefully) application extension.
#define  IJX_MARKER_APP1    0xe1   // Unsupported application specific extensions.
#define  IJX_MARKER_APP2    0xe2 
#define  IJX_MARKER_APP3    0xe3 
#define  IJX_MARKER_APP4    0xe4 
#define  IJX_MARKER_APP5    0xe5 
#define  IJX_MARKER_APP6    0xe6 
#define  IJX_MARKER_APP7    0xe7 
#define  IJX_MARKER_APP8    0xe8 
#define  IJX_MARKER_APP9    0xe9 
#define  IJX_MARKER_APP10   0xea 
#define  IJX_MARKER_APP11   0xeb 
#define  IJX_MARKER_APP12   0xec 
#define  IJX_MARKER_APP13   0xed 
#define  IJX_MARKER_APP14   0xee   // Adobe-specific application extension.

#define  IJX_MARKER_JPG1    0xf0   // From 0xf0 to 0xfd.
#define  IJX_MARKER_JPG2    0xf1   // From 0xf0 to 0xfd.
#define  IJX_MARKER_JPG3    0xf2   // From 0xf0 to 0xfd.
#define  IJX_MARKER_JPG4    0xf3   // From 0xf0 to 0xfd.
#define  IJX_MARKER_JPG5    0xf4   // From 0xf0 to 0xfd.
#define  IJX_MARKER_JPG6    0xf5   // From 0xf0 to 0xfd.
#define  IJX_MARKER_JPG7    0xf6   // From 0xf0 to 0xfd.
#define  IJX_MARKER_JPG8    0xf7   // From 0xf0 to 0xfd.
#define  IJX_MARKER_JPG9    0xf8   // From 0xf0 to 0xfd.
#define  IJX_MARKER_JPG10   0xf9   // From 0xf0 to 0xfd.
#define  IJX_MARKER_JPG11   0xfa   // From 0xf0 to 0xfd.
#define  IJX_MARKER_JPG12   0xfb   // From 0xf0 to 0xfd.
#define  IJX_MARKER_JPG13   0xfc   // From 0xf0 to 0xfd.
#define  IJX_MARKER_JPG14   0xfd   // From 0xf0 to 0xfd.
#define  IJX_MARKER_COM     0xfe


#define  IJX_JPEGBUFMODE_MCUORIMGCOEFF     0x0
#define  IJX_JPEGBUFMODE_MCUANDIMGCOEFF    0x1
#define  IJX_JPEGBUFMODE_MCUIMGCOEFFSHARE  0x2

/*
//  Status
*/
#define  IJX_STATUS_START         0
#define  IJX_STATUS_INIT          1
#define  IJX_STATUS_APP0          2
#define  IJX_STATUS_DQT           4 
#define  IJX_STATUS_DHT           8
#define  IJX_STATUS_DQHT          (4|8)
#define  IJX_STATUS_PROCESS       16
#define  IJX_STATUS_FRAME         32
#define  IJX_STATUS_SCAN          64

#define  IJX_STATUS_CREATEDCOEFF  0x10000000

#define  _IJX_MAKEVERSION_16U(major, minor) ((Ipp16u)( (((Ipp16u)(major))<<8)+((minor)&0xff) ))
#define  _IJX_MIN(a,b) ((a)>(b)?(b):(a))
#define  _IJX_MAX(a,b) ((a)>(b)?(a):(b))


#endif

/* EOF */

